//package com.lu.sb210222server.heart;
//
//import io.netty.channel.Channel;
//import io.netty.channel.ChannelInitializer;
//import io.netty.handler.timeout.IdleStateHandler;
//
//public class HeartbeatInitializer extends ChannelInitializer<Channel> {
//    @Override
//    protected void initChannel(Channel channel) throws Exception {
//        channel.pipeline()
//                //五秒没有收到消息 将IdleStateHandler 添加到 ChannelPipeline 中
//                .addLast(new IdleStateHandler(5, 0, 0))//(8)
//                .addLast(new HeartbeatDecoder())//(9)
//                .addLast(new HeartBeatSimpleHandle());//(10)
//    }
//}
